home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / upplow / upplow.frm < prev    next >
Text File  |  1995-03-01  |  3KB  |  125 lines

  1. VERSION 2.00
  2. Begin Form Form1 
  3.    BorderStyle     =   3  'Fixed Double
  4.    Caption         =   "Type Text into the Boxes to See What Happens"
  5.    ClientHeight    =   1710
  6.    ClientLeft      =   2070
  7.    ClientTop       =   2265
  8.    ClientWidth     =   5715
  9.    ControlBox      =   0   'False
  10.    Height          =   2145
  11.    Left            =   1995
  12.    LinkTopic       =   "Form1"
  13.    MaxButton       =   0   'False
  14.    MinButton       =   0   'False
  15.    ScaleHeight     =   1710
  16.    ScaleWidth      =   5715
  17.    Top             =   1905
  18.    Width           =   5865
  19.    Begin CommandButton Command1 
  20.       Cancel          =   -1  'True
  21.       Caption         =   "E&xit"
  22.       Height          =   375
  23.       Index           =   1
  24.       Left            =   4680
  25.       TabIndex        =   6
  26.       Top             =   1200
  27.       Width           =   855
  28.    End
  29.    Begin TextBox Text1 
  30.       Height          =   285
  31.       Index           =   2
  32.       Left            =   1320
  33.       TabIndex        =   5
  34.       Text            =   "Text1"
  35.       Top             =   840
  36.       Width           =   4215
  37.    End
  38.    Begin TextBox Text1 
  39.       Height          =   285
  40.       Index           =   1
  41.       Left            =   1320
  42.       TabIndex        =   4
  43.       Text            =   "Text1"
  44.       Top             =   480
  45.       Width           =   4215
  46.    End
  47.    Begin TextBox Text1 
  48.       Height          =   285
  49.       Index           =   0
  50.       Left            =   1320
  51.       TabIndex        =   3
  52.       Text            =   "Text1"
  53.       Top             =   120
  54.       Width           =   4215
  55.    End
  56.    Begin Label Label1 
  57.       Alignment       =   1  'Right Justify
  58.       BackColor       =   &H00C0C0C0&
  59.       Caption         =   "Lower:"
  60.       Height          =   255
  61.       Index           =   2
  62.       Left            =   0
  63.       TabIndex        =   2
  64.       Top             =   840
  65.       Width           =   1215
  66.    End
  67.    Begin Label Label1 
  68.       Alignment       =   1  'Right Justify
  69.       BackColor       =   &H00C0C0C0&
  70.       Caption         =   "Upper:"
  71.       Height          =   255
  72.       Index           =   1
  73.       Left            =   0
  74.       TabIndex        =   1
  75.       Top             =   480
  76.       Width           =   1215
  77.    End
  78.    Begin Label Label1 
  79.       Alignment       =   1  'Right Justify
  80.       BackColor       =   &H00C0C0C0&
  81.       Caption         =   "Normal:"
  82.       Height          =   255
  83.       Index           =   0
  84.       Left            =   0
  85.       TabIndex        =   0
  86.       Top             =   120
  87.       Width           =   1215
  88.    End
  89. End
  90. ' SetUpLo.Frm - Demo the SetUpLo Function
  91. ' 95/03/02 - Copyright 1995, Larry Rebich, The Bridge, Inc.
  92.  
  93.     Option Explicit
  94.     DefInt A-Z
  95.  
  96. ' Command Indexes
  97.     Const IndexHelp = 0
  98.     Const IndexExit = 1
  99.  
  100. Sub Command1_Click (Index As Integer)
  101.     Select Case Index
  102.         Case IndexHelp
  103.             Form2.Show
  104.         Case IndexExit
  105.             End
  106.     End Select
  107. End Sub
  108.  
  109. Sub Form_Load ()
  110.     BackColor = &HC0C0C0
  111.     Move (Screen.Width - Width) \ 2, 500
  112.     Dim x As Integer    'returns true if OK
  113.     x = ForceUpperOrLowerCase(Text1(1), True)    'force lower
  114.     x = ForceUpperOrLowerCase(Text1(2), False)    'force lower
  115.     Text1(1) = UCase$(Text1(1))
  116.     Text1(2) = LCase$(Text1(2))
  117.     Form2.Show
  118. End Sub
  119.  
  120. Sub Text1_GotFocus (Index As Integer)
  121.     Text1(Index).SelStart = 0
  122.     Text1(Index).SelLength = 999
  123. End Sub
  124.  
  125.